# Pax **Repository Path**: mirrors/Pax ## Basic Information - **Project Name**: Pax - **Description**: 银河系中最快的 JavaScript 打包工具,除 CommonJS require() 外,完全支持 ECMAScript 模块语法(导入/导出) - **Primary Language**: Rust - **License**: Not specified - **Default Branch**: master - **Homepage**: https://www.oschina.net/p/Pax - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2018-07-24 - **Last Updated**: 2026-02-21 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Pax The [fastest](#is-it-fast) JavaScript bundler in the galaxy. Fully supports ECMAScript module syntax (`import`/`export`) in addition to CommonJS `require()`. - [Why do I need it?](#why-do-i-need-it) - [How do I get it?](#how-do-i-get-it) - [How do I use it?](#how-do-i-use-it) - [Does it do source maps?](#does-it-do-source-maps) - [Modules?](#modules) - [What are the options?](#what-are-the-options) - [Is it fast?](#is-it-fast) # Why do I need it? Because your bundler is **too slow**. You know the feeling. You make that tweak, hit ⌘S ⌘Tab ⌘R, and… **nothing changes**. You get the old version. You beat the bundler. You wait a few seconds, hit ⌘R again, and your changes finally show up. But it’s too late—**you’ve lost momentum.** It’s the wrong shade of pink. You spelled “menu” with a z. The bug still happens sometimes. Rinse. Repeat. Ten cycles later, things are looking good. It’s time to `git commit`. But you spent **more time waiting than working**. And it’s your bundler’s fault. Pax is a bundler. But you’ll never beat it. Why? - It’s parallelized. It makes the most of your cores. - It’s minimal. It isn’t bogged down by features you don’t need. - It knows exactly enough about JavaScript to handle dependency resolution. It doesn’t even bother parsing most of your source code. Don’t waste time waiting for your bundler to do its thing. Use Pax while you’re developing, and **iterate to your heart’s content**. Use your super-cool, magical, slow-as-molasses bundler for releases, when you don’t care how long it takes to run. # How do I get it? ```sh > cargo install pax ``` If you don’t have `cargo`, install it with [https://rustup.rs](https://rustup.rs/). # How do I use it? ```js // index.js: const itt = require('itt') const math = require('./math') console.log(itt.range(10).map(math.square).join(' ')) // math.js: exports.square = x => x * x ``` ```sh > px index.js bundle.js ``` Slap on a `